package tvp.ltdd.fake_call_sms;

import tvp.ltdd.fake_call_sms.activity.Tab;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;


public class MainActivity extends Activity {
	private Button btn_qck_call, btn_qck_sms, btn_call, btn_sms;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		
		btn_qck_call = (Button)findViewById(R.id.btn_qck_call);
		btn_qck_sms = (Button)findViewById(R.id.btn_qck_sms);
		btn_call = (Button)findViewById(R.id.btn_call);
		btn_sms = (Button)findViewById(R.id.btn_sms);
		
		btn_qck_call.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, Tab.class );
				intent.putExtra("position", 0);
				startActivity(intent);
			}
		});
		
		btn_qck_sms.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, Tab.class );
				intent.putExtra("position", 1);
				startActivity(intent);
			}
		});
		
		btn_call.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, Tab.class );
				intent.putExtra("position", 2);
				startActivity(intent);
			}
		});
		
		btn_sms.setOnClickListener(new OnClickListener() {
			
			@Override
			public void onClick(View v) {
				Intent intent = new Intent(MainActivity.this, Tab.class );
				intent.putExtra("position", 3);
				startActivity(intent);
			}
		});
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.main, menu);
		return true;
	}

}
